ci: add timeout and fail-fast settings to CI workflow#178
Merged
Conversation
Co-authored-by: askpt <2493377+askpt@users.noreply.github.com>
4 tasks
Contributor
There was a problem hiding this comment.
Pull request overview
Updates the GitHub Actions CI workflow to improve cost control and cross-platform failure visibility for the existing OS test matrix.
Changes:
- Added a 15-minute timeout to the
buildjob to cap runaway executions. - Set
strategy.fail-fast: falseso macOS/Ubuntu/Windows matrix jobs all complete even if one fails.
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #178 +/- ##
=======================================
Coverage 59.17% 59.17%
=======================================
Files 6 6
Lines 1984 1984
Branches 143 143
=======================================
Hits 1174 1174
Misses 810 810 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
askpt
approved these changes
Mar 2, 2026
This was referenced Mar 13, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Adds cost protection and full OS visibility to the cross-platform test matrix with two low-risk optimizations.
Changes
timeout-minutes: 15on build job — caps runaway jobs at 15 minutes instead of GitHub's 6-hour default, protecting against excessive runner costs (especially on 10× more expensive macOS runners)fail-fast: falsein matrix strategy — ensures all OS jobs (macOS, Ubuntu, Windows) complete even when one fails, eliminating re-runs needed to diagnose OS-specific vs universal failuresBoth changes are additive safety measures with no impact on passing workflows.
Original prompt
This section details on the original issue you should resolve
<issue_title>[ci-coach] ci: add timeout and fail-fast settings to CI workflow</issue_title>
<issue_description>### Summary
Two targeted, low-risk CI optimizations that improve cost protection and debugging visibility for the cross-platform test matrix.
Optimizations
1. Job Timeout (
timeout-minutes: 15)Type: Resource Sizing
Impact: Prevents runaway macOS/Windows runners from consuming excess minutes
Risk: Low
Changes:
timeout-minutes: 15to thebuildjobRationale: VS Code extension tests including compile, lint, and test should complete well under 15 minutes. Without an explicit timeout, the GitHub default is 6 hours — a stuck job on macOS (which costs ~10× more than Ubuntu) could burn significant runner minutes before expiring. A 15-minute cap acts as a cost safety net.
Detailed Analysis
The CI matrix runs on 3 OSes. macOS runner pricing (
$0.16/min) is approximately 10× Ubuntu ($0.016/min). A stuck job at the default 6-hour timeout on macOS = ~$57.60 per occurrence. With a 15-minute cap, worst-case exposure is ~$2.40 per occurrence.Typical VS Code extension CI runs are observed to complete in 3–8 minutes across all platforms.
2. Matrix
fail-fast: falseType: Visibility / Debugging
Impact: All OS jobs complete in a single run — full failure picture without re-running
Risk: Low
Changes:
fail-fast: falseto the matrixstrategyRationale: The default
fail-fast: truecancels all sibling matrix jobs as soon as one fails. For a cross-platform extension this obscures whether a failure is OS-specific or universal, forcing additional re-runs to gather complete data. Settingfail-fast: falseensures all three OS results are always available in a single workflow run, which is especially valuable when triaging tree-sitter native binding failures that can be OS-specific.Detailed Analysis
With
fail-fast: true(current): if the macOS job fails early, Ubuntu and Windows jobs are cancelled. The developer must push another commit or manually re-run to see if the failure is macOS-specific.With
fail-fast: false(proposed): all three jobs complete, giving an immediate complete picture of cross-platform health.Cost impact of
fail-fast: false: negligible — jobs that were previously cancelled still run, but typically only for the remaining minutes of their normal execution time (not the full 15-minute timeout).Expected Impact
Testing Recommendations
To create a pull request with the changes: